﻿using System.Collections.Generic;
using XLua;
#if USE_UNI_LUA
using LuaAPI = UniLua.Lua;
using RealStatePtr = UniLua.ILuaState;
using LuaCSFunction = UniLua.CSharpFunctionDelegate;
#else
using LuaAPI = XLua.LuaDLL.Lua;
using RealStatePtr = System.IntPtr;
using LuaCSFunction = XLua.LuaDLL.lua_CSFunction;
#endif

namespace XLua.CSObjectWrap
{
    using Utils = XLua.Utils;

    public class UnityEngineRendererWrap
    {
        public static void __Register(RealStatePtr L)
        {
            ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
            System.Type type = typeof(UnityEngine.Renderer);
            Utils.BeginObjectRegister(type, L, translator, 0, 8, 31, 27);

            Utils.RegisterFunc(L, Utils.METHOD_IDX, "ResetBounds", _m_ResetBounds);
            Utils.RegisterFunc(L, Utils.METHOD_IDX, "ResetLocalBounds", _m_ResetLocalBounds);
            Utils.RegisterFunc(L, Utils.METHOD_IDX, "HasPropertyBlock", _m_HasPropertyBlock);
            Utils.RegisterFunc(L, Utils.METHOD_IDX, "SetPropertyBlock", _m_SetPropertyBlock);
            Utils.RegisterFunc(L, Utils.METHOD_IDX, "GetPropertyBlock", _m_GetPropertyBlock);
            Utils.RegisterFunc(L, Utils.METHOD_IDX, "GetMaterials", _m_GetMaterials);
            Utils.RegisterFunc(L, Utils.METHOD_IDX, "GetSharedMaterials", _m_GetSharedMaterials);
            Utils.RegisterFunc(
                L,
                Utils.METHOD_IDX,
                "GetClosestReflectionProbes",
                _m_GetClosestReflectionProbes
            );

            Utils.RegisterFunc(L, Utils.GETTER_IDX, "bounds", _g_get_bounds);
            Utils.RegisterFunc(L, Utils.GETTER_IDX, "localBounds", _g_get_localBounds);
            Utils.RegisterFunc(L, Utils.GETTER_IDX, "enabled", _g_get_enabled);
            Utils.RegisterFunc(L, Utils.GETTER_IDX, "isVisible", _g_get_isVisible);
            Utils.RegisterFunc(L, Utils.GETTER_IDX, "shadowCastingMode", _g_get_shadowCastingMode);
            Utils.RegisterFunc(L, Utils.GETTER_IDX, "receiveShadows", _g_get_receiveShadows);
            Utils.RegisterFunc(L, Utils.GETTER_IDX, "forceRenderingOff", _g_get_forceRenderingOff);
            Utils.RegisterFunc(
                L,
                Utils.GETTER_IDX,
                "staticShadowCaster",
                _g_get_staticShadowCaster
            );
            Utils.RegisterFunc(
                L,
                Utils.GETTER_IDX,
                "motionVectorGenerationMode",
                _g_get_motionVectorGenerationMode
            );
            Utils.RegisterFunc(L, Utils.GETTER_IDX, "lightProbeUsage", _g_get_lightProbeUsage);
            Utils.RegisterFunc(
                L,
                Utils.GETTER_IDX,
                "reflectionProbeUsage",
                _g_get_reflectionProbeUsage
            );
            Utils.RegisterFunc(
                L,
                Utils.GETTER_IDX,
                "renderingLayerMask",
                _g_get_renderingLayerMask
            );
            Utils.RegisterFunc(L, Utils.GETTER_IDX, "rendererPriority", _g_get_rendererPriority);
            Utils.RegisterFunc(L, Utils.GETTER_IDX, "rayTracingMode", _g_get_rayTracingMode);
            Utils.RegisterFunc(L, Utils.GETTER_IDX, "sortingLayerName", _g_get_sortingLayerName);
            Utils.RegisterFunc(L, Utils.GETTER_IDX, "sortingLayerID", _g_get_sortingLayerID);
            Utils.RegisterFunc(L, Utils.GETTER_IDX, "sortingOrder", _g_get_sortingOrder);
            Utils.RegisterFunc(
                L,
                Utils.GETTER_IDX,
                "allowOcclusionWhenDynamic",
                _g_get_allowOcclusionWhenDynamic
            );
            Utils.RegisterFunc(
                L,
                Utils.GETTER_IDX,
                "isPartOfStaticBatch",
                _g_get_isPartOfStaticBatch
            );
            Utils.RegisterFunc(
                L,
                Utils.GETTER_IDX,
                "worldToLocalMatrix",
                _g_get_worldToLocalMatrix
            );
            Utils.RegisterFunc(
                L,
                Utils.GETTER_IDX,
                "localToWorldMatrix",
                _g_get_localToWorldMatrix
            );
            Utils.RegisterFunc(
                L,
                Utils.GETTER_IDX,
                "lightProbeProxyVolumeOverride",
                _g_get_lightProbeProxyVolumeOverride
            );
            Utils.RegisterFunc(L, Utils.GETTER_IDX, "probeAnchor", _g_get_probeAnchor);
            Utils.RegisterFunc(L, Utils.GETTER_IDX, "lightmapIndex", _g_get_lightmapIndex);
            Utils.RegisterFunc(
                L,
                Utils.GETTER_IDX,
                "realtimeLightmapIndex",
                _g_get_realtimeLightmapIndex
            );
            Utils.RegisterFunc(
                L,
                Utils.GETTER_IDX,
                "lightmapScaleOffset",
                _g_get_lightmapScaleOffset
            );
            Utils.RegisterFunc(
                L,
                Utils.GETTER_IDX,
                "realtimeLightmapScaleOffset",
                _g_get_realtimeLightmapScaleOffset
            );
            Utils.RegisterFunc(L, Utils.GETTER_IDX, "materials", _g_get_materials);
            Utils.RegisterFunc(L, Utils.GETTER_IDX, "material", _g_get_material);
            Utils.RegisterFunc(L, Utils.GETTER_IDX, "sharedMaterial", _g_get_sharedMaterial);
            Utils.RegisterFunc(L, Utils.GETTER_IDX, "sharedMaterials", _g_get_sharedMaterials);

            Utils.RegisterFunc(L, Utils.SETTER_IDX, "bounds", _s_set_bounds);
            Utils.RegisterFunc(L, Utils.SETTER_IDX, "localBounds", _s_set_localBounds);
            Utils.RegisterFunc(L, Utils.SETTER_IDX, "enabled", _s_set_enabled);
            Utils.RegisterFunc(L, Utils.SETTER_IDX, "shadowCastingMode", _s_set_shadowCastingMode);
            Utils.RegisterFunc(L, Utils.SETTER_IDX, "receiveShadows", _s_set_receiveShadows);
            Utils.RegisterFunc(L, Utils.SETTER_IDX, "forceRenderingOff", _s_set_forceRenderingOff);
            Utils.RegisterFunc(
                L,
                Utils.SETTER_IDX,
                "staticShadowCaster",
                _s_set_staticShadowCaster
            );
            Utils.RegisterFunc(
                L,
                Utils.SETTER_IDX,
                "motionVectorGenerationMode",
                _s_set_motionVectorGenerationMode
            );
            Utils.RegisterFunc(L, Utils.SETTER_IDX, "lightProbeUsage", _s_set_lightProbeUsage);
            Utils.RegisterFunc(
                L,
                Utils.SETTER_IDX,
                "reflectionProbeUsage",
                _s_set_reflectionProbeUsage
            );
            Utils.RegisterFunc(
                L,
                Utils.SETTER_IDX,
                "renderingLayerMask",
                _s_set_renderingLayerMask
            );
            Utils.RegisterFunc(L, Utils.SETTER_IDX, "rendererPriority", _s_set_rendererPriority);
            Utils.RegisterFunc(L, Utils.SETTER_IDX, "rayTracingMode", _s_set_rayTracingMode);
            Utils.RegisterFunc(L, Utils.SETTER_IDX, "sortingLayerName", _s_set_sortingLayerName);
            Utils.RegisterFunc(L, Utils.SETTER_IDX, "sortingLayerID", _s_set_sortingLayerID);
            Utils.RegisterFunc(L, Utils.SETTER_IDX, "sortingOrder", _s_set_sortingOrder);
            Utils.RegisterFunc(
                L,
                Utils.SETTER_IDX,
                "allowOcclusionWhenDynamic",
                _s_set_allowOcclusionWhenDynamic
            );
            Utils.RegisterFunc(
                L,
                Utils.SETTER_IDX,
                "lightProbeProxyVolumeOverride",
                _s_set_lightProbeProxyVolumeOverride
            );
            Utils.RegisterFunc(L, Utils.SETTER_IDX, "probeAnchor", _s_set_probeAnchor);
            Utils.RegisterFunc(L, Utils.SETTER_IDX, "lightmapIndex", _s_set_lightmapIndex);
            Utils.RegisterFunc(
                L,
                Utils.SETTER_IDX,
                "realtimeLightmapIndex",
                _s_set_realtimeLightmapIndex
            );
            Utils.RegisterFunc(
                L,
                Utils.SETTER_IDX,
                "lightmapScaleOffset",
                _s_set_lightmapScaleOffset
            );
            Utils.RegisterFunc(
                L,
                Utils.SETTER_IDX,
                "realtimeLightmapScaleOffset",
                _s_set_realtimeLightmapScaleOffset
            );
            Utils.RegisterFunc(L, Utils.SETTER_IDX, "materials", _s_set_materials);
            Utils.RegisterFunc(L, Utils.SETTER_IDX, "material", _s_set_material);
            Utils.RegisterFunc(L, Utils.SETTER_IDX, "sharedMaterial", _s_set_sharedMaterial);
            Utils.RegisterFunc(L, Utils.SETTER_IDX, "sharedMaterials", _s_set_sharedMaterials);

            Utils.EndObjectRegister(type, L, translator, null, null, null, null, null);

            Utils.BeginClassRegister(type, L, __CreateInstance, 1, 0, 0);

            Utils.EndClassRegister(type, L, translator);
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int __CreateInstance(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
                if (LuaAPI.lua_gettop(L) == 1)
                {
                    var gen_ret = new UnityEngine.Renderer();
                    translator.Push(L, gen_ret);

                    return 1;
                }
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return LuaAPI.luaL_error(L, "invalid arguments to UnityEngine.Renderer constructor!");
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _m_ResetBounds(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);

                {
                    gen_to_be_invoked.ResetBounds();

                    return 0;
                }
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _m_ResetLocalBounds(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);

                {
                    gen_to_be_invoked.ResetLocalBounds();

                    return 0;
                }
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _m_HasPropertyBlock(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);

                {
                    var gen_ret = gen_to_be_invoked.HasPropertyBlock();
                    LuaAPI.lua_pushboolean(L, gen_ret);

                    return 1;
                }
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _m_SetPropertyBlock(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);

                int gen_param_count = LuaAPI.lua_gettop(L);

                if (
                    gen_param_count == 2
                    && translator.Assignable<UnityEngine.MaterialPropertyBlock>(L, 2)
                )
                {
                    UnityEngine.MaterialPropertyBlock _properties =
                        (UnityEngine.MaterialPropertyBlock)
                            translator.GetObject(L, 2, typeof(UnityEngine.MaterialPropertyBlock));

                    gen_to_be_invoked.SetPropertyBlock(_properties);

                    return 0;
                }
                if (
                    gen_param_count == 3
                    && translator.Assignable<UnityEngine.MaterialPropertyBlock>(L, 2)
                    && LuaTypes.LUA_TNUMBER == LuaAPI.lua_type(L, 3)
                )
                {
                    UnityEngine.MaterialPropertyBlock _properties =
                        (UnityEngine.MaterialPropertyBlock)
                            translator.GetObject(L, 2, typeof(UnityEngine.MaterialPropertyBlock));
                    int _materialIndex = LuaAPI.xlua_tointeger(L, 3);

                    gen_to_be_invoked.SetPropertyBlock(_properties, _materialIndex);

                    return 0;
                }
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }

            return LuaAPI.luaL_error(
                L,
                "invalid arguments to UnityEngine.Renderer.SetPropertyBlock!"
            );
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _m_GetPropertyBlock(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);

                int gen_param_count = LuaAPI.lua_gettop(L);

                if (
                    gen_param_count == 2
                    && translator.Assignable<UnityEngine.MaterialPropertyBlock>(L, 2)
                )
                {
                    UnityEngine.MaterialPropertyBlock _properties =
                        (UnityEngine.MaterialPropertyBlock)
                            translator.GetObject(L, 2, typeof(UnityEngine.MaterialPropertyBlock));

                    gen_to_be_invoked.GetPropertyBlock(_properties);

                    return 0;
                }
                if (
                    gen_param_count == 3
                    && translator.Assignable<UnityEngine.MaterialPropertyBlock>(L, 2)
                    && LuaTypes.LUA_TNUMBER == LuaAPI.lua_type(L, 3)
                )
                {
                    UnityEngine.MaterialPropertyBlock _properties =
                        (UnityEngine.MaterialPropertyBlock)
                            translator.GetObject(L, 2, typeof(UnityEngine.MaterialPropertyBlock));
                    int _materialIndex = LuaAPI.xlua_tointeger(L, 3);

                    gen_to_be_invoked.GetPropertyBlock(_properties, _materialIndex);

                    return 0;
                }
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }

            return LuaAPI.luaL_error(
                L,
                "invalid arguments to UnityEngine.Renderer.GetPropertyBlock!"
            );
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _m_GetMaterials(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);

                {
                    System.Collections.Generic.List<UnityEngine.Material> _m =
                        (System.Collections.Generic.List<UnityEngine.Material>)
                            translator.GetObject(
                                L,
                                2,
                                typeof(System.Collections.Generic.List<UnityEngine.Material>)
                            );

                    gen_to_be_invoked.GetMaterials(_m);

                    return 0;
                }
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _m_GetSharedMaterials(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);

                {
                    System.Collections.Generic.List<UnityEngine.Material> _m =
                        (System.Collections.Generic.List<UnityEngine.Material>)
                            translator.GetObject(
                                L,
                                2,
                                typeof(System.Collections.Generic.List<UnityEngine.Material>)
                            );

                    gen_to_be_invoked.GetSharedMaterials(_m);

                    return 0;
                }
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _m_GetClosestReflectionProbes(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);

                {
                    System.Collections.Generic.List<UnityEngine.Rendering.ReflectionProbeBlendInfo> _result =
                        (System.Collections.Generic.List<UnityEngine.Rendering.ReflectionProbeBlendInfo>)
                            translator.GetObject(
                                L,
                                2,
                                typeof(System.Collections.Generic.List<UnityEngine.Rendering.ReflectionProbeBlendInfo>)
                            );

                    gen_to_be_invoked.GetClosestReflectionProbes(_result);

                    return 0;
                }
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_bounds(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                translator.PushUnityEngineBounds(L, gen_to_be_invoked.bounds);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_localBounds(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                translator.PushUnityEngineBounds(L, gen_to_be_invoked.localBounds);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_enabled(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                LuaAPI.lua_pushboolean(L, gen_to_be_invoked.enabled);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_isVisible(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                LuaAPI.lua_pushboolean(L, gen_to_be_invoked.isVisible);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_shadowCastingMode(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                translator.Push(L, gen_to_be_invoked.shadowCastingMode);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_receiveShadows(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                LuaAPI.lua_pushboolean(L, gen_to_be_invoked.receiveShadows);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_forceRenderingOff(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                LuaAPI.lua_pushboolean(L, gen_to_be_invoked.forceRenderingOff);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_staticShadowCaster(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                LuaAPI.lua_pushboolean(L, gen_to_be_invoked.staticShadowCaster);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_motionVectorGenerationMode(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                translator.Push(L, gen_to_be_invoked.motionVectorGenerationMode);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_lightProbeUsage(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                translator.Push(L, gen_to_be_invoked.lightProbeUsage);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_reflectionProbeUsage(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                translator.Push(L, gen_to_be_invoked.reflectionProbeUsage);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_renderingLayerMask(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                LuaAPI.xlua_pushuint(L, gen_to_be_invoked.renderingLayerMask);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_rendererPriority(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                LuaAPI.xlua_pushinteger(L, gen_to_be_invoked.rendererPriority);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_rayTracingMode(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                translator.Push(L, gen_to_be_invoked.rayTracingMode);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_sortingLayerName(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                LuaAPI.lua_pushstring(L, gen_to_be_invoked.sortingLayerName);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_sortingLayerID(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                LuaAPI.xlua_pushinteger(L, gen_to_be_invoked.sortingLayerID);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_sortingOrder(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                LuaAPI.xlua_pushinteger(L, gen_to_be_invoked.sortingOrder);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_allowOcclusionWhenDynamic(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                LuaAPI.lua_pushboolean(L, gen_to_be_invoked.allowOcclusionWhenDynamic);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_isPartOfStaticBatch(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                LuaAPI.lua_pushboolean(L, gen_to_be_invoked.isPartOfStaticBatch);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_worldToLocalMatrix(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                translator.Push(L, gen_to_be_invoked.worldToLocalMatrix);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_localToWorldMatrix(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                translator.Push(L, gen_to_be_invoked.localToWorldMatrix);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_lightProbeProxyVolumeOverride(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                translator.Push(L, gen_to_be_invoked.lightProbeProxyVolumeOverride);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_probeAnchor(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                translator.Push(L, gen_to_be_invoked.probeAnchor);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_lightmapIndex(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                LuaAPI.xlua_pushinteger(L, gen_to_be_invoked.lightmapIndex);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_realtimeLightmapIndex(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                LuaAPI.xlua_pushinteger(L, gen_to_be_invoked.realtimeLightmapIndex);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_lightmapScaleOffset(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                translator.PushUnityEngineVector4(L, gen_to_be_invoked.lightmapScaleOffset);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_realtimeLightmapScaleOffset(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                translator.PushUnityEngineVector4(L, gen_to_be_invoked.realtimeLightmapScaleOffset);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_materials(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                translator.Push(L, gen_to_be_invoked.materials);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_material(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                translator.Push(L, gen_to_be_invoked.material);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_sharedMaterial(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                translator.Push(L, gen_to_be_invoked.sharedMaterial);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _g_get_sharedMaterials(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                translator.Push(L, gen_to_be_invoked.sharedMaterials);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 1;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_bounds(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                UnityEngine.Bounds gen_value;
                translator.Get(L, 2, out gen_value);
                gen_to_be_invoked.bounds = gen_value;
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_localBounds(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                UnityEngine.Bounds gen_value;
                translator.Get(L, 2, out gen_value);
                gen_to_be_invoked.localBounds = gen_value;
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_enabled(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                gen_to_be_invoked.enabled = LuaAPI.lua_toboolean(L, 2);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_shadowCastingMode(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                UnityEngine.Rendering.ShadowCastingMode gen_value;
                translator.Get(L, 2, out gen_value);
                gen_to_be_invoked.shadowCastingMode = gen_value;
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_receiveShadows(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                gen_to_be_invoked.receiveShadows = LuaAPI.lua_toboolean(L, 2);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_forceRenderingOff(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                gen_to_be_invoked.forceRenderingOff = LuaAPI.lua_toboolean(L, 2);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_staticShadowCaster(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                gen_to_be_invoked.staticShadowCaster = LuaAPI.lua_toboolean(L, 2);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_motionVectorGenerationMode(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                UnityEngine.MotionVectorGenerationMode gen_value;
                translator.Get(L, 2, out gen_value);
                gen_to_be_invoked.motionVectorGenerationMode = gen_value;
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_lightProbeUsage(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                UnityEngine.Rendering.LightProbeUsage gen_value;
                translator.Get(L, 2, out gen_value);
                gen_to_be_invoked.lightProbeUsage = gen_value;
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_reflectionProbeUsage(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                UnityEngine.Rendering.ReflectionProbeUsage gen_value;
                translator.Get(L, 2, out gen_value);
                gen_to_be_invoked.reflectionProbeUsage = gen_value;
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_renderingLayerMask(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                gen_to_be_invoked.renderingLayerMask = LuaAPI.xlua_touint(L, 2);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_rendererPriority(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                gen_to_be_invoked.rendererPriority = LuaAPI.xlua_tointeger(L, 2);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_rayTracingMode(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                UnityEngine.Experimental.Rendering.RayTracingMode gen_value;
                translator.Get(L, 2, out gen_value);
                gen_to_be_invoked.rayTracingMode = gen_value;
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_sortingLayerName(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                gen_to_be_invoked.sortingLayerName = LuaAPI.lua_tostring(L, 2);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_sortingLayerID(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                gen_to_be_invoked.sortingLayerID = LuaAPI.xlua_tointeger(L, 2);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_sortingOrder(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                gen_to_be_invoked.sortingOrder = LuaAPI.xlua_tointeger(L, 2);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_allowOcclusionWhenDynamic(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                gen_to_be_invoked.allowOcclusionWhenDynamic = LuaAPI.lua_toboolean(L, 2);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_lightProbeProxyVolumeOverride(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                gen_to_be_invoked.lightProbeProxyVolumeOverride = (UnityEngine.GameObject)
                    translator.GetObject(L, 2, typeof(UnityEngine.GameObject));
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_probeAnchor(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                gen_to_be_invoked.probeAnchor = (UnityEngine.Transform)
                    translator.GetObject(L, 2, typeof(UnityEngine.Transform));
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_lightmapIndex(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                gen_to_be_invoked.lightmapIndex = LuaAPI.xlua_tointeger(L, 2);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_realtimeLightmapIndex(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                gen_to_be_invoked.realtimeLightmapIndex = LuaAPI.xlua_tointeger(L, 2);
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_lightmapScaleOffset(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                UnityEngine.Vector4 gen_value;
                translator.Get(L, 2, out gen_value);
                gen_to_be_invoked.lightmapScaleOffset = gen_value;
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_realtimeLightmapScaleOffset(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                UnityEngine.Vector4 gen_value;
                translator.Get(L, 2, out gen_value);
                gen_to_be_invoked.realtimeLightmapScaleOffset = gen_value;
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_materials(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                gen_to_be_invoked.materials = (UnityEngine.Material[])
                    translator.GetObject(L, 2, typeof(UnityEngine.Material[]));
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_material(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                gen_to_be_invoked.material = (UnityEngine.Material)
                    translator.GetObject(L, 2, typeof(UnityEngine.Material));
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_sharedMaterial(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                gen_to_be_invoked.sharedMaterial = (UnityEngine.Material)
                    translator.GetObject(L, 2, typeof(UnityEngine.Material));
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }

        [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
        static int _s_set_sharedMaterials(RealStatePtr L)
        {
            try
            {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                UnityEngine.Renderer gen_to_be_invoked = (UnityEngine.Renderer)
                    translator.FastGetCSObj(L, 1);
                gen_to_be_invoked.sharedMaterials = (UnityEngine.Material[])
                    translator.GetObject(L, 2, typeof(UnityEngine.Material[]));
            }
            catch (System.Exception gen_e)
            {
                return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
            }
            return 0;
        }
    }
}
